this.tooltip = function(){    
    /* CONFIG */        
        xOffset = -30;
        yOffset = 10;        
    $("a.t").hover(function(e){
        this.t = this.title;
        this.title = "";
        $("body").append("<p id='tooltip'>"+ this.t +"</p>");
        $("#tooltip")
            .css("top",(e.pageY - xOffset) + "px")
            .css("left",(e.pageX + yOffset) + "px")
            .show(700,"easeOutBounce");
    },
    function(){
        this.title = this.t;        
        $("#tooltip").remove();
    });    
    $("a.t").mousemove(function(e){
        $("#tooltip")
            .css("top",(e.pageY - xOffset) + "px")
            .css("left",(e.pageX + yOffset) + "px");
    });            
};
(function($){
	$.fn.juizScrollTo = function(speed){
		if(!speed) var speed = 'slow';
		return this.each(function(){
			$(this).click(function(){
				var goscroll = false;
				var the_hash = $(this).attr("href");
				var regex = new RegExp("(.*)\#(.*)","gi");
				var the_element = '';
				if(the_hash.match("\#")) {
					the_hash = the_hash.replace(regex,"$2");
					if($("#"+the_hash).length>0) {
						the_element = "#" + the_hash;
						goscroll = true;
					}
					else if($("a[name=" + the_hash + "]").length>0) {
						the_element = "a[name=" + the_hash + "]";
						goscroll = true;
					}
					if(goscroll) {
						var container = 'html';
						if ($.browser.webkit) container = 'body';
						$(container).animate({
							scrollTop:$(the_element).offset().top
						}, speed);
						return false;
					}
				}
			});
		});
	};
})(jQuery);
$(document).ready(function(){
tooltip();
$('a[href^="#"]').juizScrollTo('slow').css('color','red');
});